#include<bits/stdc++.h>
using namespace std;
struct number{
    long long a1,a2,b1,b2,val;
    friend number operator*(const number &va,const number &vb){
        return {va.a1 + vb.a1,va.a2 + vb.a2,va.b1 + vb.b1,va.b2 + vb.b2,va.val*vb.val};
    }
};
long long jc[20];
long long C(int n,int m){
    return jc[n]/jc[n - m]/jc[m];
}
int main(){
    jc[0] = 1;
    for(int i = 1;i<=11;i++){
        jc[i] = jc[i - 1]*i;
    }
    for(int i = 0;i<=10;i++){
        for(int j = 0;j <= 10;j++){
            if(i + j <= 10){
                vector<number> v1;
                for(int k = 0;k <= i;k++){
                    v1.push_back({k,i - k,0,0,C(i,k)});
                }
                vector<number> v2;
                for(int k = 0;k <= j;k++){
                    v2.push_back({0,0,k,j - k,C(j,k)});
                }
                vector<number> res;
                for(number p1 : v1){
                    for(number p2 : v2){
                        res.push_back(p1*p2);
                    }
                }
                cout<<i<<' '<<j<<' ';
                for(number v : res){
                    cout<<v.val<<' ';
                }
                cout<<'\n';
            }
        }
    }
}